html,
body,
#root {
  height: 100%;
  margin: 0;
  padding: 0;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial,
    'Noto Sans', sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol',
    'Noto Color Emoji';
}

.colorWeak {
  filter: invert(80%);
}

.ant-layout {
  min-height: 100vh;
}

.ant-pro-sider.ant-layout-sider.ant-pro-sider-fixed {
  left: unset;
}

canvas {
  display: block;
}

body {
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

ul,
ol {
  list-style: none;
}

@media (max-width: 768px) {
  .ant-table {
    width: 100%;
    overflow-x: auto;

    &-thead > tr,
    &-tbody > tr {
      > th,
      > td {
        white-space: pre;

        > span {
          display: block;
        }
      }
    }
  }
}

.hide-tab-bar {
  .runtime-keep-alive-tabs-layout {
    display: none !important;
  }
}

.runtime-keep-alive-tabs-layout {
  .ant-pro-layout-bg-list {
    background-image: none !important;
    background-color: #fff !important;
  }

  .ant-tabs-nav-wrap {
    padding-top: 8px;
    background-color: #eee;
  }

  .ant-tabs-nav .ant-tabs-tab {
    margin-left: 0 !important;
    background-color: transparent !important;
    position: relative;
    border: none !important;
    color: inherit !important;

    &:hover {
      background-color: #f8f8f8 !important;
      &::before,
      & + .ant-tabs-tab::before {
        display: none;
      }
    }

    &:first-of-type {
      margin-left: 5px !important;
    }

    &:last-of-type {
      margin-right: 20px !important;
    }

    &.ant-tabs-tab-active {
      background-color: #fff !important;
      .ant-tabs-tab-btn {
        color: inherit !important;
      }
    }

    &:not(:hover):not(.ant-tabs-tab-active) {
      border-radius: 0 !important;
      border-color: transparent;
    }

    &:not(.ant-tabs-tab-active):not(:first-of-type)::before {
      content: '';
      width: 1px;
      height: 60%;
      background-color: #ddd;
      position: absolute;
      top: 20%;
      left: -1px;
    }

    &.ant-tabs-tab-active + .ant-tabs-tab::before {
      display: none;
    }

    &:last-of-type::before {
      height: 100% !important;
    }
  }
}

// 重制logo样式
.ant-pro .ant-pro-layout .ant-pro-sider-logo {
  border: none;
}
